import Vue from 'vue'
import Vuex from 'vuex'

Vue.use(Vuex)

export default new Vuex.Store({
  state: {
    count: ''
  },
  mutations: {
    setUserCount(state, sum) {
      state.count = sum
    },
    add(state) {
      state.count++
    },
    addN(state, step) {
      state.count += step
    },
    sub(state) {
      state.count--
    },
  },
  actions: {
  },
  modules: {
  }
})
